<template>
    <!-- 全局组件 -->
    <AppBanner :list="list" />
</template>

<script>
import { ref } from 'vue'
import { getBanner } from '@/api'
export default {
    setup(props) {
        const list = ref([])
        getBanner().then(res => {
            console.log(res);
            if (res.msg == '操作成功') {
                list.value = res.result
                console.log(list.value);
            }
        }).catch(err => {
            console.log(err);
        })

        return { list }
    }
}
</script>

<style lang="less" scoped></style>  